#coding:UTF-8
from bs4 import BeautifulSoup
import urllib2
import sys
reload(sys)
sys.setdefaultencoding('utf8')
url = "http://www.csrc.gov.cn/pub/zjhpublicofbj/gongg/201708/t20170825_322575.htm"
user_agent = 'Mozilla/5.0 (Windows NT 6.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/48.0.2564.82 Safari/537.36'
headers = {'User-Agent': user_agent, 'timeout': 60}
request = urllib2.Request(url, headers=headers)
response = urllib2.urlopen(request)
content = response.read()
# print content
soup = BeautifulSoup(content,'lxml')
c = soup.select('#lTitle')
for t in  c:
    print t.get_text().encode('utf-8')

cc = soup.select('#ContentRegion > div > p')
for tt in cc:
    print tt.get_text().encode('utf-8') + "\n"
